from typing import List

from tortoise.contrib.pydantic import pydantic_model_creator
from models.area import Area

AreaOutSchema = pydantic_model_creator(Area, name='AreaOutSchema')


class AreaSubSchema(AreaOutSchema):
    subs: List[AreaOutSchema]